<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>主页</title>
    <style>
        body {
            font-family: 'Courier New', Courier, monospace;
            background-color: #000;
            color: #00ff00;
            text-align: center;
            margin: 0;
            padding: 0;
        }
        .header {
            padding: 20px;
            background-color: #001f3f;
            position: relative;
        }
        .header h1 {
            margin: 0;
            font-size: 3em;
            display: inline-block;
        }
        .header .auth-buttons {
            position: absolute;
            top: 20px;
            right: 20px;
        }
        .header .auth-button {
            background-color: #00ff00;
            color: #000;
            border: none;
            padding: 10px 20px;
            font-size: 1em;
            cursor: pointer;
            margin-left: 10px;
        }
        .main-content {
            padding: 20px;
        }
        .main-content h2 {
            font-size: 2em;
        }
        .main-content p {
            font-size: 1.2em;
        }
        .footer {
            padding: 10px;
            background-color: #001f3f;
            position: fixed;
            bottom: 0;
            width: 100%;
        }
        .footer p {
            margin: 0;
            font-size: 1em;
        }
        .glow {
            text-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00, 0 0 30px #00ff00, 0 0 40px #00ff00;
        }
    </style>
</head>
<body>
    <div class="header">
        <h1 class="glow">未来之城</h1>
        <div class="auth-buttons">
            {% if user %}
                <button class="auth-button" onclick="location.href='/auth/logout'">退出</button>
            {% else %}
                <button class="auth-button" onclick="location.href='/auth/register'">注册</button>
                <button class="auth-button" onclick="location.href='/auth/login'">登录</button>
            {% endif %}
        </div>
    </div>
    <div class="main-content">
        <h2 class="glow">欢迎【
            {% if user %}
                {{ user.username }}
            {% else %}
                游客
            {% endif %}
            】来到未来之城</h2>
        <p>探索未知，体验未来科技，开启你的科幻之旅。</p>
        <p>在这里，每一刻都是新的冒险，每一处都是未知的奇迹。</p>
        <p><a href="/article">新闻列表</a> </p>
    </div>
    <div class="footer">
        <p class="glow">版权所有 &copy; 2025 未来之城</p>
    </div>
</body>
</html>
